package com.ruoyi.methods.service.impl;

import com.ruoyi.methods.domain.PaymentMethods;
import com.ruoyi.methods.mapper.PaymentMethodsMapper;
import com.ruoyi.methods.service.IPaymentMethodsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 支付方式管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-10-11
 */
@Service
public class PaymentMethodsServiceImpl implements IPaymentMethodsService 
{
    @Autowired
    private PaymentMethodsMapper paymentMethodsMapper;

    /**
     * 查询支付方式管理
     * 
     * @param paymentMethodId 支付方式管理主键
     * @return 支付方式管理
     */
    @Override
    public PaymentMethods selectPaymentMethodsByPaymentMethodId(Long paymentMethodId)
    {
        return paymentMethodsMapper.selectPaymentMethodsByPaymentMethodId(paymentMethodId);
    }

    /**
     * 查询支付方式管理列表
     * 
     * @param paymentMethods 支付方式管理
     * @return 支付方式管理
     */
    @Override
    public List<PaymentMethods> selectPaymentMethodsList(PaymentMethods paymentMethods)
    {
        return paymentMethodsMapper.selectPaymentMethodsList(paymentMethods);
    }

    /**
     * 新增支付方式管理
     * 
     * @param paymentMethods 支付方式管理
     * @return 结果
     */
    @Override
    public int insertPaymentMethods(PaymentMethods paymentMethods)
    {
        return paymentMethodsMapper.insertPaymentMethods(paymentMethods);
    }

    /**
     * 修改支付方式管理
     * 
     * @param paymentMethods 支付方式管理
     * @return 结果
     */
    @Override
    public int updatePaymentMethods(PaymentMethods paymentMethods)
    {
        return paymentMethodsMapper.updatePaymentMethods(paymentMethods);
    }

    /**
     * 批量删除支付方式管理
     * 
     * @param paymentMethodIds 需要删除的支付方式管理主键
     * @return 结果
     */
    @Override
    public int deletePaymentMethodsByPaymentMethodIds(Long[] paymentMethodIds)
    {
        return paymentMethodsMapper.deletePaymentMethodsByPaymentMethodIds(paymentMethodIds);
    }

    /**
     * 删除支付方式管理信息
     * 
     * @param paymentMethodId 支付方式管理主键
     * @return 结果
     */
    @Override
    public int deletePaymentMethodsByPaymentMethodId(Long paymentMethodId)
    {
        return paymentMethodsMapper.deletePaymentMethodsByPaymentMethodId(paymentMethodId);
    }
}
